<?php

namespace App\Http\Controllers\Wap;

use App\Models\Lives;
use App\Models\Seos;
use Illuminate\Http\Request;
use App\Http\Controllers\Controller;

class LiveController extends Controller
{
    protected $chanel_id = 3;//设置导航选中标志

    public function __construct()
    {
        view()->share('seo',Seos::seo('SEO-LIVE'));
    }

    public function index(Request $request)
    {
        $lists = Lives::list(20);
        if($request->ajax()){
            return $this->writeJson(0,$lists);
        }
        $lists = json_encode($lists);
        return view('wap.live.index',compact('lists'));
    }



}